package org.eenie.commonlib.exts

import android.widget.ImageView
import com.alibaba.android.arouter.launcher.ARouter
import com.bumptech.glide.Glide
import com.bumptech.glide.load.resource.bitmap.BitmapTransitionOptions
import com.eenie.common.base.BaseActivity

fun BaseActivity.startRoute(path: String) {
    ARouter.getInstance().build(path)
            .navigation()
}


fun ImageView.load(url: String) {
    Glide.with(context)
            .asBitmap()
            .load(url)
            .transition(BitmapTransitionOptions.withCrossFade())
            .into(this)
}



